<?php
$this->pageTitle = 'My Task Calendar - ' . Yii::app()->name;
$this->sectionTitle = 'Task Calendar';

Yii::app()->clientScript->registerCssFile(Yii::app()->request->baseUrl . '/vendors/fullcalendar/fullcalendar.css');
Yii::app()->clientScript->registerScriptFile(Yii::app()->request->baseUrl . '/vendors/fullcalendar/fullcalendar.min.js');
Yii::app()->clientScript->registerScript('taskcal', '
    $("#calendar").fullCalendar({
        header: {
                left: "prev,next today",
                center: "title",
                right: "month,basicWeek,basicDay"
        },
        events: ' . '"' . CController::createUrl('todo/jsonData') . '"' . '
});
    ', CClientScript::POS_READY);
?>

<div id="calendar" style="font-size: 12px;"></div>